/* 
 * File:   widget_panel.hpp
 * Author: jolo
 *
 * Created on 5. Oktober 2011, 19:02
 */

#ifndef WIDGET_PANEL_HPP
#define	WIDGET_PANEL_HPP

#include "group_box.hpp"

class QLineEdit;
class QSpinBox;
class QTextEdit;

namespace widgets
{
    class labelled_line_edit;
    class labelled_spin_box;
    class labelled_text_edit;
    
    class field_label;

    class widget_panel : public group_box
    {
        Q_OBJECT
    public:
        widget_panel(QWidget* p = 0, const QString& title = "");
        virtual ~widget_panel();

        void add(labelled_line_edit* w);
        void add(labelled_text_edit* w);
        void add(labelled_spin_box* w);
        
    protected:
        void add(field_label* lbl, QLineEdit* w);
        void add(field_label* lbl, QSpinBox* w);
        void add(field_label* lbl, QTextEdit* w);
        
    private:
        int lblCol_;
        int wCol_;
        int row_;
    };
}

#endif	/* WIDGET_PANEL_HPP */

